package com.skytech.tax.customsdatawarehouse.electronicport.proceedspayment.importpayment.domain.entity;

import com.alibaba.fastjson.JSONObject;
import com.skytech.tax.customsdatawarehouse.electronicport.proceedspayment.exportproceeds.domain.entity.ExportProceedsSimple;

/**
 * @author Lianhong
 * @since 2021/11/19
 */
public class ImportPayment {

    private String entryId;
    private String importPayment;
    private String storageTime;         //入库时间
    private String iEDate;
    private String dDate;
    private String socialCreditCode;

    public ImportPayment() {
    }

    public ImportPayment(String entryId, String socialCreditCode, JSONObject importPayment) {
        this.entryId = entryId;
        JSONObject curGpiHeadJg = importPayment.getJSONObject("curGpiHeadJg");
        this.iEDate = curGpiHeadJg.getString("iEDate");
        this.dDate = curGpiHeadJg.getString("dDate");
        this.socialCreditCode = socialCreditCode;
        this.importPayment = importPayment.toJSONString();
    }

    public String getEntryId() {
        return entryId;
    }

    public void setEntryId(String entryId) {
        this.entryId = entryId;
    }

    public String getImportPayment() {
        return importPayment;
    }

    public void setImportPayment(String importPayment) {
        this.importPayment = importPayment;
    }

    public String getStorageTime() {
        return storageTime;
    }

    public void setStorageTime(String storageTime) {
        this.storageTime = storageTime;
    }

    public String getiEDate() {
        return iEDate;
    }

    public void setiEDate(String iEDate) {
        this.iEDate = iEDate;
    }

    public String getdDate() {
        return dDate;
    }

    public void setdDate(String dDate) {
        this.dDate = dDate;
    }

    public String getSocialCreditCode() {
        return socialCreditCode;
    }

    public void setSocialCreditCode(String socialCreditCode) {
        this.socialCreditCode = socialCreditCode;
    }

    public ImportPaymentSimple buildImportPaymentSimple() {
        ImportPaymentSimple simple = new ImportPaymentSimple();
        simple.setEntryId(entryId);
        simple.setdDate(dDate);
        return simple;
    }
}
